package com.dsjy.yf.address.service;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.dsjy.yf.address.entity.dataobject.StreetDO;

import java.util.List;

/**
 * @author whj
 * @version 1.0
 * @date 2021-01-19 9:47
 */
public interface StreetService {

    /**
     * 根据区划代码查找街路巷弄信息
     *
     * @param parentCode
     * @return
     */
    List<StreetDO> searchStreetWithParentCode(Integer parentCode, Boolean flag);

    /**
     * 增删改
     *
     * @param operate
     * @param streetDO
     * @return
     */
    Integer addUpdDel(String operate, StreetDO streetDO);

    /**
     * 增加路巷弄
     *
     * @param streetDO
     * @return
     */
    Integer addStreet(StreetDO streetDO);


    /**
     * 更新修改
     *
     * @param streetDO
     * @return
     */
    Integer updStreet(StreetDO streetDO);

    /**
     * 分页查询
     * @param pageNum
     * @param pageSize
     * @param wrapper
     * @return
     */
    IPage searchWithPage(Integer pageNum, Integer pageSize, QueryWrapper wrapper);
}
